package com.situ.entity;

import com.alibaba.fastjson.JSONObject;
import java.util.*;
import java.time.*;
/**
 * PY_BillDetail实体类
 * 
 * @author 
 *
 */
public class PyBilldetail {
	/***/
	private Object ID; 
	/***/
	private String BillNo; 
	/***/
	private String UserNo; 
	/***/
	private String CostTypeCode; 
	/***/
	private Integer Amount; 
	/***/
	private Double Price; 
	/***/
	private Double DetailMoney; 
	/***/
	private Double RealMoney; 
	/***/
	private Integer Balance; 
	/***/
	private java.time.Instant BalanceDate; 
	/**
	 * 实例化
	 */
	public PyBilldetail() {
		super();
	}
	/**
	 * 实例化
	 * 
	 * @param obj
	 */
	public PyBilldetail(JSONObject obj) {
		this();
		this.setID(obj.get("ID"));
		if (obj.get("BillNo") instanceof String) {
			this.setBillNo((String) obj.get("BillNo"));
		}
		if (obj.get("UserNo") instanceof String) {
			this.setUserNo((String) obj.get("UserNo"));
		}
		if (obj.get("CostTypeCode") instanceof String) {
			this.setCostTypeCode((String) obj.get("CostTypeCode"));
		}
		if (obj.get("Amount") instanceof Number) {
			this.setAmount(((Number) obj.get("Amount")).intValue());
		}
		if (obj.get("Price") instanceof Number) {
			this.setPrice(((Number) obj.get("Price")).doubleValue());
		}
		if (obj.get("DetailMoney") instanceof Number) {
			this.setDetailMoney(((Number) obj.get("DetailMoney")).doubleValue());
		}
		if (obj.get("RealMoney") instanceof Number) {
			this.setRealMoney(((Number) obj.get("RealMoney")).doubleValue());
		}
		if (obj.get("Balance") instanceof Number) {
			this.setBalance(((Number) obj.get("Balance")).intValue());
		}
		if (obj.get("BalanceDate") instanceof java.time.Instant) {
			this.setBalanceDate((java.time.Instant) obj.get("BalanceDate"));
		}
	}
	
	/**
	 * 将当前对象转换为JsonObject
	 * 
	 * @return
	 */
	public JSONObject toJson() {
		JSONObject result = new JSONObject();
		if (this.getID() != null) {
			result.put("ID",this.getID());
		}
		if (this.getBillNo() != null) {
			result.put("BillNo",this.getBillNo());
		}
		if (this.getUserNo() != null) {
			result.put("UserNo",this.getUserNo());
		}
		if (this.getCostTypeCode() != null) {
			result.put("CostTypeCode",this.getCostTypeCode());
		}
		if (this.getAmount() != null) {
			result.put("Amount",this.getAmount());
		}
		if (this.getPrice() != null) {
			result.put("Price",this.getPrice());
		}
		if (this.getDetailMoney() != null) {
			result.put("DetailMoney",this.getDetailMoney());
		}
		if (this.getRealMoney() != null) {
			result.put("RealMoney",this.getRealMoney());
		}
		if (this.getBalance() != null) {
			result.put("Balance",this.getBalance());
		}
		if (this.getBalanceDate() != null) {
			result.put("BalanceDate",this.getBalanceDate());
		}
		return result;
	}
	
	
	/**
	 * 获取ID
	 * 
	 * @return
	 */
	public Object getID() {
		return ID;
	}

	/**
	 * 设置ID
	 * 
	 * @param ID
	 */
	public void setID(Object ID) {
		this.ID = ID;
	}
	
	/**
	 * 获取BillNo
	 * 
	 * @return
	 */
	public String getBillNo() {
		return BillNo;
	}

	/**
	 * 设置BillNo
	 * 
	 * @param BillNo
	 */
	public void setBillNo(String BillNo) {
		this.BillNo = BillNo;
	}
	
	/**
	 * 获取UserNo
	 * 
	 * @return
	 */
	public String getUserNo() {
		return UserNo;
	}

	/**
	 * 设置UserNo
	 * 
	 * @param UserNo
	 */
	public void setUserNo(String UserNo) {
		this.UserNo = UserNo;
	}
	
	/**
	 * 获取CostTypeCode
	 * 
	 * @return
	 */
	public String getCostTypeCode() {
		return CostTypeCode;
	}

	/**
	 * 设置CostTypeCode
	 * 
	 * @param CostTypeCode
	 */
	public void setCostTypeCode(String CostTypeCode) {
		this.CostTypeCode = CostTypeCode;
	}
	
	/**
	 * 获取Amount
	 * 
	 * @return
	 */
	public Integer getAmount() {
		return Amount;
	}

	/**
	 * 设置Amount
	 * 
	 * @param Amount
	 */
	public void setAmount(Integer Amount) {
		this.Amount = Amount;
	}
	
	/**
	 * 获取Price
	 * 
	 * @return
	 */
	public Double getPrice() {
		return Price;
	}

	/**
	 * 设置Price
	 * 
	 * @param Price
	 */
	public void setPrice(Double Price) {
		this.Price = Price;
	}
	
	/**
	 * 获取DetailMoney
	 * 
	 * @return
	 */
	public Double getDetailMoney() {
		return DetailMoney;
	}

	/**
	 * 设置DetailMoney
	 * 
	 * @param DetailMoney
	 */
	public void setDetailMoney(Double DetailMoney) {
		this.DetailMoney = DetailMoney;
	}
	
	/**
	 * 获取RealMoney
	 * 
	 * @return
	 */
	public Double getRealMoney() {
		return RealMoney;
	}

	/**
	 * 设置RealMoney
	 * 
	 * @param RealMoney
	 */
	public void setRealMoney(Double RealMoney) {
		this.RealMoney = RealMoney;
	}
	
	/**
	 * 获取Balance
	 * 
	 * @return
	 */
	public Integer getBalance() {
		return Balance;
	}

	/**
	 * 设置Balance
	 * 
	 * @param Balance
	 */
	public void setBalance(Integer Balance) {
		this.Balance = Balance;
	}
	
	/**
	 * 获取BalanceDate
	 * 
	 * @return
	 */
	public java.time.Instant getBalanceDate() {
		return BalanceDate;
	}

	/**
	 * 设置BalanceDate
	 * 
	 * @param BalanceDate
	 */
	public void setBalanceDate(java.time.Instant BalanceDate) {
		this.BalanceDate = BalanceDate;
	}

	@Override
	public String toString() {
		return "PyBilldetail [ID=" + ID + " , BillNo=" + BillNo + " , UserNo=" + UserNo + " , CostTypeCode=" + CostTypeCode + " , Amount=" + Amount + " , Price=" + Price + " , DetailMoney=" + DetailMoney + " , RealMoney=" + RealMoney + " , Balance=" + Balance + " , BalanceDate=" + BalanceDate + "  ]";
	
	}
	
	
}
